home *** CD-ROM | disk | FTP | other *** search
/ CD ROM Paradise Collection 4 / CD ROM Paradise Collection 4 1995 Nov.iso / program / swags_z.zip / STRINGS.SWG / 0036_Get Path from path-mask.pas < prev    next >
Pascal/Delphi Source File  |  1993-09-26  |  718b  |  21 lines

  1. {*****************************************************************************
  2.  * Function ...... GetPath()
  3.  * Purpose ....... To return the path from a path/mask string
  4.  * Parameters .... Path       String to extract the path from
  5.  * Returns ....... <Path> minus the mask
  6.  * Notes ......... Trailing slash *IS* included if it is there
  7.  *                 (eg, C:\PROGRAM\PASCAL\)
  8.  * Author ........ Martin Richardson
  9.  * Date .......... May 13, 1992
  10.  *****************************************************************************}
  11. FUNCTION GetPath( Path: DirStr ): DirStr;
  12. VAR
  13.    dir : DirStr;
  14.    name: NameStr;
  15.    ext : ExtStr;
  16. BEGIN
  17.      FSPLIT( path, dir, name, ext );
  18.      GetPath := Dir;
  19. END;
  20.  
  21.